package com.fowo.api.model.purchase.samples;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.format.DateTimeFormat;
import com.alibaba.excel.annotation.write.style.ContentStyle;
import com.alibaba.excel.enums.poi.HorizontalAlignmentEnum;
import javax.validation.constraints.*;
import lombok.Getter;
import lombok.Setter;

/** 购买样品子表 导入导出辅助模型 */
@Getter
@Setter
public class PurchaseSamplesExcelPo {

  @ExcelProperty(value = "所属寻源管理")
  private Long parentSourcingManageTaskId;

  @ExcelIgnore
  @ExcelProperty(value = "所属寻源管理")
  private Long parentSourcingManage;

  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "所属供应商采购单")
  private String parentSupplierOrderSupplierOrder;

  @ExcelIgnore
  @ExcelProperty(value = "所属供应商采购单")
  private Long parentSupplierOrder;

  @NotBlank(message = "名称不能为空")
  @Size(max = 50, message = "名称长度不能超过20")
  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "*名称")
  private String name;

  @NotNull(message = "单价不能为空")
  @ExcelProperty(value = "*单价")
  private java.math.BigDecimal unitPrice;

  @NotNull(message = "实付金额不能为空")
  @ExcelProperty(value = "*实付金额")
  private java.math.BigDecimal payAmount;

  @DateTimeFormat("yyyy年MM月dd日HH:mm:ss")
  @ExcelProperty(value = "收货时间")
  private java.util.Date receivingTime;
}
